# Maintainer: Síle Ekaterin Liszka <sheila@vulpine.house>
pkgname=perl-json
_pkgreal=JSON
pkgver=4.07
pkgrel=0
pkgdesc="Perl module implementing a JSON encoder/decoder"
url="https://metacpan.org/release/JSON"
arch="noarch"
license="GPL-1.0-or-later OR Artistic-1.0-Perl"
depends="perl"
subpackages="$pkgname-doc"
source="https://cpan.metacpan.org/authors/id/I/IS/ISHIGAKI/JSON-$pkgver.tar.gz"
builddir="$srcdir/$_pkgreal-$pkgver"

build() {
	PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
	make
}

check() {
	make test
}

package() {
	make DESTDIR="$pkgdir" install
	find "$pkgdir" -name perllocal.pod -delete
	find "$pkgdir" -name .packlist -delete
}

sha512sums="
0a9a59ca07b79b48e2055e49542727deeacca1b7d0807dfe90dd4dbbe9989a74fb200e60bfe4ec7090fea7fea89cb00879ef97e87d7ca4a113046b9eab170b70  JSON-4.07.tar.gz
"
